home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / comm / ca29_3.zip / LEARN.DOC < prev    next >
Text File  |  1992-11-30  |  21KB  |  825 lines

  1. COM-AND LEARN Script
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.           ---------------------------------------
  13.                COM-AND LEARN Script
  14.           Script generator (learning) for COM-AND
  15.           ---------------------------------------
  16.  
  17.  
  18.  
  19.  
  20.     COM-AND, and the LEARN script are copyright 1992 by CABER Soft-
  21.     ware.  COM-AND is distributed freely and may be copied by anyone
  22.     for any number of machines, for purposes of evaluation.  The
  23.     author offers COM-AND and its accessory programs as "shareware".
  24.     If you USE the program after evaluating it, you MUST pay for it.
  25.  
  26.  
  27.  
  28.     The complete user license and registration information is to be
  29.     found in the file REGISTER.DOC.  Limitations on redistribution
  30.     of COM-AND are set out in the file VENDOR.DOC.    These two files
  31.     are included with the COM-AND program release.
  32.  
  33.  
  34.  
  35.                  CABER Software
  36.                  R. (Scott) McGinnis
  37.                  P.O. Box 3607 Mdse Mart
  38.                  Chicago, IL 60654-0607
  39.  
  40.                  GEnie, Delphi: TARTAN
  41.                  CIS .......... 73147,2665
  42.                  Internet ..... 73147.2665@compuserve.com
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54. Version 1.0: 921012
  55.  
  56. COM-AND LEARN Script
  57.  
  58.  
  59.                  Table of Contents
  60.                  -----------------
  61.  
  62. I.    Introduction  .............................................. page 1
  63.  
  64.     A. What is COM-AND? ........................................ page 1
  65.     B. The LEARN script ........................................ page 1
  66.  
  67. II.    Running LEARN .............................................. page 2
  68.  
  69. III.    LEARN function ............................................. page 3
  70.  
  71. IV.    LEARN commands ............................................. page 6
  72.  
  73.     ESC    Exit LEARN ......................................... page 6
  74.     F1    Load accessory ..................................... page 6
  75.     F2    Execute script ..................................... page 6
  76.     F3    Change drive:subdir ................................ page 6
  77.     F4    Set default download subdir ........................ page 6
  78.     F5    Toggle line/char ................................... page 7
  79.     F6    Toggle learn hold .................................. page 7
  80.     F7    Toggle logging file ................................ page 7
  81.     F9    Toggle log hold .................................... page 7
  82.     F10    Information screen ................................. page 7
  83.     Alt-C    Clear screen ....................................... page 8
  84.     Alt-E    Toggle echo ........................................ page 8
  85.     Alt-D    Dial ............................................... page 8
  86.     Alt-G    Toggle blankline ................................... page 8
  87.     Alt-H    Hangup ............................................. page 8
  88.     Alt-L    Toggle 25/43 ....................................... page 8
  89.     Alt-Q    Toggle CR/CRLF ..................................... page 8
  90.     Alt-N    Encrypt/decrypt .................................... page 9
  91.     Alt-P    Set comm parms ..................................... page 9
  92.     Alt-Z    Toggle masking ..................................... page 9
  93.     PgUp    Upload ............................................. page 9
  94.     PgDn    Download ........................................... page 10
  95.     Alt-F10 Shell to DOS ....................................... page 10
  96.     Alt-0/9 Send macro ......................................... page 10
  97.     Ctl-End Send break ......................................... page 10
  98.     Ctl-Prt Toggle print ....................................... page 10
  99.  
  100. V.    Modifying Scripts .......................................... page 11
  101.  
  102. VI.    Program Requirements ....................................... page 12
  103.  
  104. VII.    Program and Author Information    ............................ page 13
  105.  
  106.  
  107.  
  108.  
  109. Version 1.0: 921012
  110.  
  111. COM-AND LEARN Script                         Page    1
  112.  
  113.  
  114. I.    Introduction
  115.  
  116.  
  117.     A. What is COM-AND?
  118.  
  119.  
  120.        COM-AND for the IBM PC and compatibles is a communications
  121.        program for use by itself, or for use with several integrated
  122.        accessory programs (which themselves may be used independently of
  123.        COM-AND).  COM-AND provides standard comm program functions:  a
  124.        dialing directory, macros, disk logging, binary and ASCII file
  125.        transfers, scripted execution and the usual schtick.
  126.  
  127.  
  128.     B.  The LEARN script
  129.  
  130.  
  131.        LEARN.CMD was created at Mike Todd's request, to aid in the
  132.        writing of scripts.    LEARN generates a script by 'comprehending'
  133.        (in a limited sense) the actions taken.  The generated script
  134.        mimics the learned session.    LEARN provides many COM-AND functions
  135.        (e.g.  DIAL (Alt-D), Accessories (F1) macros (Alt-0/9), and so on)
  136.        within its environment.
  137.  
  138.  
  139.        This document discusses the function of the LEARN.CMD script.
  140.  
  141.  
  142.  
  143.  
  144.  
  145.  
  146.  
  147.  
  148.  
  149.  
  150.  
  151.  
  152.  
  153.  
  154.  
  155.  
  156.  
  157.  
  158.  
  159.  
  160.  
  161.  
  162.  
  163.  
  164. Version 1.0: 921012
  165.  
  166. COM-AND LEARN Script                         Page    2
  167.  
  168.  
  169. II.    Running LEARN
  170.  
  171.  
  172.     The LEARN script is invoked through COM-AND's script processor (F2).
  173.     When invoked, LEARN first asks for a script file name.    When this
  174.     request is satisfied, LEARN then displays a screen with:
  175.  
  176.           . a received text area
  177.           . a keyboard buffer
  178.           . a summary of available commands
  179.           . a status line
  180.  
  181.  
  182.     The LEARN script adjusts to the screen size in use.  You may wish to
  183.     use LEARN in 43 line mode generally (if you have an EGA or VGA adap-
  184.     tor), to provide a maximum space for received text.
  185.  
  186.  
  187.     LEARN logs the initial state of COM-AND (options, comm parms, and so
  188.     on) to the output file when the file is created.  If you enter LEARN
  189.     with 43 screen lines, a SET 43 is placed at the beginning of the
  190.     output file.  You may edit this out after exiting LEARN, or during
  191.     the LEARN session.
  192.  
  193.  
  194.     Note: any subdirectory/drive change you perform within LEARN is
  195.     'cancelled' when you exit LEARN.  Similarly, the screen from which
  196.     LEARN was executed is restored.
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204.  
  205.  
  206.  
  207.  
  208.  
  209.  
  210.  
  211.  
  212.  
  213.  
  214.  
  215.  
  216.  
  217.  
  218.  
  219. Version 1.0: 921012
  220.  
  221. COM-AND LEARN Script                         Page    3
  222.  
  223.  
  224. III.    LEARN function
  225.  
  226.  
  227.     LEARN follows your actions.  When a key is pressed, its equivalent
  228.     is displayed in the keyboard display.  When RETURN is pressed, the
  229.     entire line (limited to 60 characters) is transmitted, and WAITFOR/
  230.     TRANSMIT statements are written to the output file.  For example:
  231.  
  232.         WAITFOR "<last received text>"
  233.         ;*IF NOT WAITFOR GOTO ...
  234.         TRANSMIT "<what was typed>"
  235.  
  236.  
  237.     LEARN writes a WAITFOR, a comment, and a TRANSMIT statement to the
  238.     output file.  The WAITFOR waits for the last line of text received.
  239.     The comment is to remind the potential author that the WAITFOR may
  240.     time out, and the action should be tested.  The TRANSMIT sends the
  241.     equivalent of what was typed out the comm port.
  242.  
  243.  
  244.     Should no text have been received between the last transmit and the
  245.     current transmit, LEARN write the following comments to the output
  246.     file:
  247.         ;
  248.         ; WAITFOR may be needed here
  249.         ;
  250.  
  251.  
  252.     Initially, LEARN is in a 'LINE' mode.  Text is buffered, and trans-
  253.     mitted only when RETURN is pressed.  Some BBSes use single characters
  254.     and control characters as commands.  LEARN may set to a 'character'
  255.     mode with the F5 toggle (see below).  In 'CHAR' mode, each character
  256.     typed results in the WAITFOR/comment/TRANSMIT statements described
  257.     above.
  258.  
  259.  
  260.     Special functions (such as Alt-D dialing, macros, and so on) may be
  261.     performed within LEARN.  The appropriate script statements are added
  262.     to the output file.  The special functions LEARN supports are listed
  263.     in the following chapter.
  264.  
  265.  
  266.     When LEARN is exited, the output file is closed, and COM-AND is reset
  267.     to a condition similar to that when LEARN was entered.    The real work
  268.     starts when LEARN is exited and you must edit the script!
  269.  
  270.  
  271.  
  272.  
  273.  
  274. Version 1.0: 921012
  275.  
  276. COM-AND LEARN Script                         Page    4
  277.  
  278.  
  279. III.    LEARN function (continued)
  280.  
  281.  
  282.     LEARN cannot capture some actions taken on-line.  For example, when
  283.     dialing PLINK direct, connecting to PLINK's modems requires one step
  284.     LEARN cannot accomodate.  For example:
  285.  
  286.         ... initial state settings
  287.         LEGEND "Script learned: "*"08/10/1989"
  288.         PRINTER OFF
  289.         SET CHAT OFF
  290.         SET KBDB OFF
  291.         ; Dialing
  292.         DIAL "1"
  293.         IF FAILED
  294.            EXIT
  295.            ENDIF
  296.         WAITFOR "2400"
  297.         ;*IF NOT WAITFOR GOTO ...
  298.         TRANSMIT "!"
  299.         ;
  300.         ; WAITFOR may be needed here
  301.         ;
  302.         TRANSMIT "!"
  303.         WAITFOR "USER ID:"
  304.         ;*IF NOT WAITFOR GOTO